package com.longxiao.mapper;

import com.longxiao.entity.CpRecord;
import com.longxiao.entity.CpStat;
import com.longxiao.vo.CpSearchParaVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CpRecordMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(CpRecord record);

    int insertSelective(CpRecord record);

    CpRecord selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(CpRecord record);

    int updateByPrimaryKey(CpRecord record);

    /*
    *积分统计信息
    */
    Integer queryTodayCp(CpSearchParaVo para);
    /**
     * 根据条件获取积分记录
     * @param userId
     * @param source
     * @param classId
     * @return
     */
    List<CpRecord> selectByCondtion(@Param("userId")String userId, @Param("source")String source, @Param("classId")Integer classId);

}